package com.ufm.security.dao;

import java.util.List;
import java.util.Map;

import org.springframework.stereotype.Repository;
import org.springframework.transaction.annotation.Transactional;

import com.ufm.security.pojo.Rights;
import com.ufm.security.pojo.RightsAndRoles;
import com.ufm.security.pojo.UsersAndRoles;
@Repository  
@Transactional
public interface RightsMapper {
	public List<Rights> findAll(Map params);
	public List<Rights> findByRoleId(int roleId);
	public void saveRoleAndRights(RightsAndRoles rightsAndRoles);
	public void deleteRoleAndRights(int roleId);
	
	public void saveRoleAndUsers(UsersAndRoles usersAndRoles);
	public void deleteRoleAndUsers(int roleId);
	
	public List<Integer> findRoleByUserId(int userId);
	public void deleteRoleByUserId(int userId);
}
